import Vue from 'vue'
import ElementUI from 'element-ui'
import 'element-ui/lib/theme-chalk/index.css'
import App from './App.vue'
import VueRouter from 'vue-router'

import VueResource from 'vue-resource'
Vue.use(VueResource);


import Login from './components/login.vue'

import Findall from './components/findall.vue'

import Findone from './components/findone.vue'

//vueRouter是vue的插件，所以需要使用use方法来加载
Vue.use(VueRouter)
Vue.use(ElementUI)
var router = new VueRouter({
  mode:'history',
  routes:[
        {
          path: '/login', 
          component: Login
        },
        {
          path: '/findall', 
          component: Findall
        },
        {
          path: '/findone', 
          component: Findone
        },
  ] 
})

new Vue({
  el: '#app',
  router,
  render: h => h(App)
})
